﻿using UnityEngine;
using System.Collections;

public class LilithAnimEvents : MonoBehaviour {

	public PlayerPhysics playerPhysics;
	public float hitDistance;

	public void onHit() {
		RaycastHit hit = playerPhysics.CheckHit(hitDistance);
		if (hit.transform != null) {
			if (hit.transform.tag == "Destroyable") {
				hit.transform.gameObject.GetComponent<DestroyScript>().onHit();
			}
		}
	}
}
